////////////////////////////////////////////////////////////////////////////////////////
//
// JSimpleSim - A machine language simulator based on SimpSim by Anne-Gert Bultena.
//
// Copyright (C) 2008 Gerardo Camorlinga, Ryan Fitzgerald, and RJ Gordon
//
// This file is part of JSimpleSim.
//
// JSimpleSim is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// JSimpleSim is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with JSimpleSim.  If not, see <http://www.gnu.org/licenses/>.
//
////////////////////////////////////////////////////////////////////////////////////////

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package jsimplesim.machine;

import jsimplesim.model.IrHexTableModel;
import jsimplesim.model.MemHexTableModel;
import jsimplesim.model.PcHexTableModel;
import jsimplesim.model.RegHexTableModel;
// Team Alpha edit:
// adding new Activation Record stack model
import jsimplesim.model.StackModel;
// end Team Alpha edit
import jsimplesim.view.JSimpleSimView;
import org.junit.After;
import org.junit.AfterClass;
import org.junit.Before;
import org.junit.BeforeClass;
import org.junit.Test;
import static org.junit.Assert.*;

/**
 *
 * @author junior
 */
public class MachineTest {

    public MachineTest() {
    }

    @BeforeClass
    public static void setUpClass() throws Exception {
        @SuppressWarnings("unused")
		MemHexTableModel mem = new MemHexTableModel();
        @SuppressWarnings("unused")
		PcHexTableModel pc = new PcHexTableModel();
        @SuppressWarnings("unused")
		IrHexTableModel ir = new IrHexTableModel();
    }

    @AfterClass
    public static void tearDownClass() throws Exception {
    }

    @Before
    public void setUp() {
    }

    @After
    public void tearDown() {
    }

    /**
     * Test of step method, of class Machine.
     */
    @Test
    public void testStep() {
        System.out.println("Testing the step...making sure it increments stuff");
        MemHexTableModel mem1 = null;
        PcHexTableModel pc1 = null;
        IrHexTableModel ir1 = null;
        RegHexTableModel reg1 = null;
        StackModel stk1 = null;
        JSimpleSimView view1 = null;
        Machine.step(mem1, pc1, ir1, reg1, stk1, view1);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }

    /**
     * Test of run method, of class Machine.
     */
    @Test
    public void testRun() throws Exception {
        System.out.println("run");
        int state = 0;
        MemHexTableModel mem1 = null;
        PcHexTableModel pc1 = null;
        IrHexTableModel ir1 = null;
        RegHexTableModel reg1 = null;
        StackModel stk1 = null;
        JSimpleSimView view1 = null;
        Machine.run(state, mem1, pc1, ir1, reg1, stk1, view1);
        // TODO review the generated test code and remove the default call to fail.
        fail("The test case is a prototype.");
    }

    @Test
    public void testFetch() throws Exception {
        System.out.println("Testing the fetch method");
        @SuppressWarnings("unused")
		PcHexTableModel pc1 = new PcHexTableModel();
        @SuppressWarnings("unused")
		MemHexTableModel mem1 = new MemHexTableModel();

    }
}